package edu.tsinghua.ddb.beans;

import java.util.List;
import java.util.Set;

import edu.tsinghua.ddb.dictionary.Column;


public class Sqlet implements SqlCmd{
	private String rawSQL;
	private int command;
	private Set<String> targets;
	private String database;
	private String table;
	private Set<Predicate> predicates;
	private List<Column> createStmt;
	private int strategy;
	/**
	 * @return the rawSQL
	 */
	public String getRawSQL() {
		return rawSQL;
	}
	/**
	 * @param rawSQL the rawSQL to set
	 */
	public void setRawSQL(String rawSQL) {
		this.rawSQL = rawSQL;
	}
	/**
	 * @return the command
	 */
	public int getCommand() {
		return command;
	}
	/**
	 * @param command the command to set
	 */
	public void setCommand(int command) {
		this.command = command;
	}
	/**
	 * @return the targets
	 */
	public Set<String> getTargets() {
		return targets;
	}
	/**
	 * @param targets the targets to set
	 */
	public void setTargets(Set<String> targets) {
		this.targets = targets;
	}
	/**
	 * @return the database
	 */
	public String getDatabase() {
		return database;
	}
	/**
	 * @param database the database to set
	 */
	public void setDatabase(String database) {
		this.database = database;
	}
	/**
	 * @return the table
	 */
	public String getTable() {
		return table;
	}
	/**
	 * @param table the table to set
	 */
	public void setTable(String table) {
		this.table = table;
	}
	/**
	 * @return the predicates
	 */
	public Set<Predicate> getPredicates() {
		return predicates;
	}
	/**
	 * @param predicates the predicates to set
	 */
	public void setPredicates(Set<Predicate> predicates) {
		this.predicates = predicates;
	}
	/**
	 * @return the strategy
	 */
	public int getStrategy() {
		return strategy;
	}
	/**
	 * @param strategy the strategy to set
	 */
	public void setStrategy(int strategy) {
		this.strategy = strategy;
	}
	/**
	 * @return the createStmt
	 */
	public List<Column> getCreateStmt() {
		return createStmt;
	}
	/**
	 * @param createStmt the createStmt to set
	 */
	public void setCreateStmt(List<Column> createStmt) {
		this.createStmt = createStmt;
	}

}
interface SqlCmd{
	int select=0x00;
	
	int createdb=0x11;
	int dropdb=0x12;
	
	int createtable=0x21;
	int droptable=0x22;
	
	int insert=0x31;
	int delete=0x32;
}
